<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script>
        // 对于基本数据类型，比较的是他们所保存的值
        var a = 1;
        var b = 1;
        alert(a == b);
        // 而对于应用数据类型，比较的是他们所保存的内存地址
        var obj1 = new Object ();
        var obj2 = new Object ();
        alert(obj1 == obj2);
    </script>
</head>
<body>
    
</body>
</html>